class CreateTheForms < ActiveRecord::Migration
  def self.up                          
    
    add_column :forms, :seeker_form, :text
    add_column :forms, :seeker_view, :text
    add_column :forms, :manager_form, :text
    add_column :forms, :manager_view, :text
    add_column :forms, :judge_form, :text
    add_column :forms, :judge_view, :text
    add_column :forms, :admin_form, :text
    add_column :forms, :admin_view, :text
    remove_column :forms, :form_content
    remove_column :forms, :markup_type
    
    add_column :cycles, :seeker_form, :text
    add_column :cycles, :seeker_view, :text
    add_column :cycles, :manager_form, :text
    add_column :cycles, :manager_view, :text
    add_column :cycles, :judge_form, :text
    add_column :cycles, :judge_view, :text
    add_column :cycles, :admin_form, :text
    add_column :cycles, :admin_view, :text
    remove_column :cycles, :form_content  
    
  end

  def self.down 
    
    remove_column :forms, :seeker_form
    remove_column :forms, :seeker_view
    remove_column :forms, :manager_form
    remove_column :forms, :manager_view
    remove_column :forms, :judge_form
    remove_column :forms, :judge_view
    remove_column :forms, :admin_form
    remove_column :forms, :admin_view
    add_column :forms, :form_content, :text  
    add_column :forms, :markup_type, :string 
    
    remove_column :cycles, :seeker_form
    remove_column :cycles, :seeker_view
    remove_column :cycles, :manager_form
    remove_column :cycles, :manager_view
    remove_column :cycles, :judge_form
    remove_column :cycles, :judge_view
    remove_column :cycles, :admin_form
    remove_column :cycles, :admin_view
    add_column :cycles, :form_content, :text       
    
  end
end
